	

     var index=0;
	$('.nav-top-center>p>a').mouseenter(function(){
		if($(this).hasClass('page1')){
			$(this).children('i').eq(0).addClass('i-trans');
    }else{
    	$(this).addClass('nav-trans').siblings('.nav-top-center>p>a').removeClass('nav-trans');
        $(this).children('i').eq(0).addClass('i-trans').siblings().removeClass('i-trans');
        
    }
  
    })
    		 $('nav').mouseleave(function(){
            $('.nav-top-center>p>a').children('i').removeClass('i-trans');	 
		 	$('.nav-top-center>p>a').removeClass('nav-trans');
    })

    // $('.nav-top-center a').mouseleave(function(){
    // 	$(this).children('i').removeClass('i-trans');	 
 	  //   $(this).removeClass('nav-trans');
    // })


$('.nav-top-center>p>a').eq(0).mouseenter(function(){
  $('.nav-top-center>p>.show').show().siblings('.nav-top-center>p>span').hide();
    $('.nav-top-center>p>span').css('marginLeft','380px');

})
$('.nav-top-center>p>a').eq(1).mouseenter(function(){
    $('.nav-top-center>p>span').eq(0).show().siblings('.nav-top-center>p>span').hide();
        $('.nav-top-center>p>span').css('marginLeft','-20px');
})

$('.nav-top-center>p>a').eq(2).mouseenter(function(){
    $('.nav-top-center>p>span').eq(1).show().siblings('.nav-top-center>p>span').hide();
    $('.nav-top-center>p>span').css('marginLeft','50px');
})
$('.nav-top-center>p>a').eq(3).mouseenter(function(){
    $('.nav-top-center>p>span').eq(2).show().siblings('.nav-top-center>p>span').hide();
     $('.nav-top-center>p>span').css('marginLeft','100px');
})
$('.nav-top-center>p>a').eq(4).mouseenter(function(){
    $('.nav-top-center>p>span').eq(3).show().siblings('.nav-top-center>p>span').hide();
    $('.nav-top-center>p>span').css('marginLeft','260px');
})

$('.nav-top-center>p>a').eq(5).mouseenter(function(){
    $('.nav-top-center>p>span').eq(4).show().siblings('.nav-top-center>p>span').hide();
      $('.nav-top-center>p>span').css('marginLeft','350px');
})

$('.nav-top-center>p>a').eq(6).mouseenter(function(){
    $('.nav-top-center>p>span').eq(5).show().siblings('.nav-top-center>p>span').hide();
     $('.nav-top-center>p>span').css('marginLeft','380px');
})

$('.nav-top-center>p>a').eq(7).mouseenter(function(){
    $('.nav-top-center>p>span').eq(6).show().siblings('.nav-top-center>p>span').hide();
      $('.nav-top-center>p>span').css('marginLeft','500px');
})
$('.nav-top-center>p>a').eq(8).mouseenter(function(){
   $('.nav-top-center>p>.show').show().siblings('.nav-top-center>p>span').hide();
 $('.nav-top-center>p>span').css('marginLeft','380px');
})

$('.nav-top-center>p>a').eq(9).mouseenter(function(){
    $('.nav-top-center>p>span').eq(7).show().siblings('.nav-top-center>p>span').hide();
     $('.nav-top-center>p>span').css('marginLeft','690px');
})
$('.nav-top-center>p>a').eq(10).mouseenter(function(){
    $('.nav-top-center>p>span').eq(8).show().siblings('.nav-top-center>p>span').hide();
     $('.nav-top-center>p>span').css('marginLeft','700px');

})
$('.nav-top-center>p>a').eq(11).mouseenter(function(){
     $('.nav-top-center>p>.show').show().siblings('.nav-top-center>p>span').hide();
   $('.nav-top-center>p>span').css('marginLeft','380px');
})

$('.nav-top-center>p>a').eq(12).mouseenter(function(){
    $('.nav-top-center>p>.show').show().siblings('.nav-top-center>p>span').hide();
    $('.nav-top-center>p>span').css('marginLeft','380px');
})
$('.nav-top-center>p>a').eq(13).mouseenter(function(){
    $('.nav-top-center>p>.show').show().siblings('.nav-top-center>p>span').hide();
      $('.nav-top-center>p>span').css('marginLeft','380px');
})

$('.nav-top-center>p>a').eq(14).mouseenter(function(){
    $('.nav-top-center>p>span').eq(9).show().siblings('.nav-top-center>p>span').hide();
    $('.nav-top-center>p>span').css('marginLeft','980px');
})
//把其他加上.show的
// 离开

$('nav').mouseleave(function(){
   $('.nav-top-center>p>.show').show().siblings('.nav-top-center>p>span').hide();
     $('.nav-top-center>p>span').css('marginLeft','380px');
})

// 轮播图

var num=0;
var timer;
function gogo(){
$(function(){
	timer=setInterval(function(){
		num++;
		$('.chang').css('left','428px')
		if(num>=2){
			num=0;
		$('.chang').css('left','50%');	
		}
			$('ul').css('left',-num*817+'px');
	},2000)
})
}
gogo();


$('.lunbo ol').children('li').hover(function(){
	clearInterval(timer);
	var index=$(this).index()*817;
	$('ul').css('left',-index+'px');

},function(){
	gogo();
})

$('.lunbo ol').children('li').eq(0).hover(function(){
	$('.chang').css('left','50%')
})
$('.lunbo ol').children('li').eq(1).hover(function(){
	$('.chang').css('left','428px')
})





